package com.demo.common.exception;

import lombok.Getter;
import lombok.Setter;

import java.util.List;

/**
 * 输出警告信息的异常
 * 主体信息以及出问题的对象名称
 *
 * @author Tiger.Zhang
 * date 2019/10/16 8:57
 **/
@Getter
@Setter
public class AlertException extends RuntimeException {

    private String msg;
    private int code = 1000;
    private List<String> names;

    public AlertException(String msg, List<String> names) {
        super(msg);
        this.msg = msg;
        this.names = names;
    }

    public AlertException(String msg) {
        this.msg = msg;
    }
}
